<div class="search-box">
	<form class="search_form layui-form" lay-filter="brand_search_form">
		{if condition="$get_site['site_name'] EQ '主站'"}
		<div class="layui-inline">
			<label class="layui-form-label">分站</label>
			<div class="layui-input-inline">
				<select name="site_id" lay-filter="site_id" id="site_id" lay-search>
					<option value="">主站</option>
					{volist name="site_list" id="list"}
					<option value="{$list.site_id}" {if condition="$list.site_id EQ SITE_ID" }selected{/if}>{$list.site_name}</option>
					{/volist}
				</select>
			</div>
		</div>
		{/if}
		<div class="layui-inline">
			<label class="layui-form-label">品牌名称</label>
			<div class="layui-input-inline">
				<input type="text" name="brand_name" autocomplete="off" class="layui-input">
			</div>
		</div>
		<div class="pack-up"></div>
	</form>
</div>
<table class="layui-hide" id="brand_list" lay-filter="brand_list"></table>
<script>
	var brand_list_url = "{:url('brand/ajaxList')}";
	var brand_delete_url = "{:url('brand/ajaxDelete')}";
	var brand_one_url = "{:url('brand/ajaxOneData')}";
	var brand_save_url = "{:url('brand/saveData')}";
	var brand_up_url = "{:url('brand/upload')}";
	var site_data_url = "{:url('brand/siteData')}";
	var brand_cols = {$cols};
</script>
<script type="text/html" id="brandToolbar">
  <div class="layui-btn-container">
    <a type="button" data-id="add_brand" data-url="{:url('brand/tplForm')}" data-title="新增品牌" class="layui-btn layui-btn-normal layui-btn-sm tap-nav" lay-event="addBrand"><i class="layui-icon layui-icon-add-1"></i>新增</a>
	{if condition="MEMBER_ID EQ '193'"}
    <button type="button" class="layui-btn layui-btn-danger layui-btn-sm" lay-event="delBrand"><i class="layui-icon layui-icon-delete"></i>删除</button>
	{/if}>
    <button type="button" class="layui-btn layui-btn-sm" id="upload_brand_template"><i class="layui-icon layui-icon-spread-left"></i>导入品牌</button>
    <a class="layui-btn layui-btn-warm layui-btn-sm" href="/static/template/brand_template.xls" target="_blank"><i class="layui-icon layui-icon-templeate-1"></i>EXCEL模板</a>
  </div>
</script>
<script type="text/html" id="brand_tool">
	<div class="layui-btn-group">
		<a class="layui-btn layui-btn-normal layui-btn-xs tap-nav" lay-event="edit" data-id="edit_brand_{{ d.brand_sign}}" data-url="{:url('brand/tplForm')}?brand_sign={{ d.brand_sign}}" data-title="修改品牌"><i class="layui-icon layui-icon-edit"></i></a>


		<a class="layui-btn layui-btn-danger layui-btn-xs hide-update" lay-event="update"><i class="layui-icon layui-icon-up"></i></a>
	</div>
</script>
<script type="text/html" id="is_whiteTpl">
	{{# if(d.is_white == 1){}}
		<div class="layui-anim circle layui-bg-green" data-title="是">
			<i class="layui-icon layui-icon-radio"></i>
		</div>
	{{# } else {}}
		<div class="layui-anim circle layui-bg-red" data-title="否">
			<i class="layui-icon layui-icon-radio"></i>
		</div>
	{{# }}}
</script>
<script type="text/html" id="is_need_certTpl">
	{{# if(d.is_need_cert == 1){}}
		<div class="layui-anim circle layui-bg-green" data-title="是">
			<i class="layui-icon layui-icon-radio"></i>
		</div>
	{{# } else {}}
		<div class="layui-anim circle layui-bg-red" data-title="否">
			<i class="layui-icon layui-icon-radio"></i>
		</div>
	{{# }}}
</script>
<script type="text/html" id="is_lock_goodsTpl">
	{{# if(d.is_lock_goods == 1){}}
		<div class="layui-anim circle layui-bg-red" data-title="锁定">
			<i class="layui-icon layui-icon-radio"></i>
		</div>
	{{# } else {}}
		<div class="layui-anim circle layui-bg-green" data-title="解锁">
			<i class="layui-icon layui-icon-radio"></i>
		</div>
	{{# }}}
</script>
<script type="text/html" id="audit_stateTpl">
	{{# if(d.audit_state == 1){}}
		<div class="layui-anim circle layui-bg-blue" data-title="通过">
			<i class="layui-icon layui-icon-radio"></i>
		</div>
	{{# } else if(d.audit_state == 0){ }}
		<div class="layui-anim circle layui-bg-orange" data-title="等待">
			<i class="layui-icon layui-icon-radio"></i>
		</div>
	{{# } else {}}
		<div class="layui-anim circle layui-bg-red" data-title="驳回">
			<i class="layui-icon layui-icon-radio"></i>
		</div>
	{{# }}}
</script>
<script type="text/html" id="brand_pictureTpl">
	{{# if(d.brand_picture_info){
		return '<img src="'+d.brand_picture_info.save_path+'" />';
		}
}}
</script>
<script src="/static/js/brand/brand.js" type="text/javascript" charset="utf-8"></script>